Skip to main content

ser.iloc[]

ser.iloc[position]

Returns the element in the Series at the given position.

Note:
  • Positions start at 0.
  • ser often comes from df.get(column_name).

species_ser
  • dog_001"dog"
  • cat_001"cat"
  • cat_002"cat"
  • dog_002"dog"
  • dog_003"dog"
  • ham_001"hamster"
  • ham_002"hamster"
  • cat_003"cat"
species_ser.iloc[2]

'cat'

species_ser.iloc[3]

'dog'